var firstorsecond = 0
function openFirst(){
    document.getElementById("questions").classList.remove("hide")
    document.getElementById("businessreg").classList.add("hide")
    document.getElementById("bodyMain").classList.toggle("heightFirst")
    document.getElementById("bodyMain").classList.toggle("heightSecond")
}
function openSecond(){
    document.getElementById("questions").classList.add("hide")
    document.getElementById("businessreg").classList.remove("hide")
    document.getElementById("bodyMain").classList.toggle("heightFirst")
    document.getElementById("bodyMain").classList.toggle("heightSecond")
}
function closenoclick(){
    setTimeout(function () {
        document.getElementById("noclick").classList.add("hide")
    }, 2000);
}
function openqusetion(){
    document.getElementById("noclick").classList.remove("hide")
    if(firstorsecond == 0){
        openFirst();
        firstorsecond = 1
        closenoclick();
    }else if(firstorsecond == 2){
        document.getElementById("bodyMain").classList.toggle("heightFirst")
        document.getElementById("bodyMain").classList.toggle("heightSecond")
        setTimeout(function () {
            openFirst();
            closenoclick();
        }, 2000);
        firstorsecond = 1
    }else if(firstorsecond == 1){
       openFirst();
        firstorsecond = 0
        closenoclick();
    }
}
function openregister(){
    document.getElementById("noclick").classList.remove("hide")
    if(firstorsecond == 0){
        openSecond();
        firstorsecond = 2
        closenoclick();
    }else if(firstorsecond == 1){
        document.getElementById("bodyMain").classList.toggle("heightFirst")
        document.getElementById("bodyMain").classList.toggle("heightSecond")
        setTimeout(function () {
            openSecond();
            closenoclick();
        }, 2000);
        firstorsecond = 2
    }else if(firstorsecond == 2){
        openSecond();
        firstorsecond = 0
        closenoclick();
    }
}